Security News
New Python Packaging Proposal Aims to Solve Phantom Dependency Problem with SBOMs
PEP 770 proposes adding SBOM support to Python packages to improve transparency and catch hidden non-Python dependencies that security tools often miss.
quad-indices
Advanced tools
Creates the indices for a quad mesh (two triangles), ideal for sprites, 2D lines, font glyphs, billboards, and other features.
var createIndices = require('quad-indices')
//basic usage:
var quad = createIndices()
// --> new Uint16Array([0, 1, 2, 0, 2, 3])
//N quads, array type:
var quad = createIndices({ count: 2, type: 'array' })
// --> [0, 1, 2, 0, 2, 3, 4, 5, 6, 4, 6, 7]
//counter-clockwise
var quad = createIndices({ clockwise: false })
// --> new Uint16Array([0, 1, 2, 2, 1, 3])
//store in existing array
var array = new Uint16Array(12)
createIndices(array, { start: 6 })
// --> new Uint16Array([0, 0, 0, 0, 0, 0, 0, 1, 2, 0, 2, 3])
quad = createIndices([array], [opt])
Creates the indices for a quad mesh. Both parameters are optional.
If array
is provided and is a Buffer or array-like object, it will be used as output instead of creating a new object.
Possible options:
count
the number of quads to index, default 1type
(string) the dtype of the returned array, default '"uint16"'clockwise
(boolean) the orientation of the indices, default truestart
the starting index to place the data into the array, default 0MIT, see LICENSE.md for details.
FAQs
creates the indices for a quad (two triangles)
We found that quad-indices demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
PEP 770 proposes adding SBOM support to Python packages to improve transparency and catch hidden non-Python dependencies that security tools often miss.
Security News
Socket CEO Feross Aboukhadijeh discusses open source security challenges, including zero-day attacks and supply chain risks, on the Cyber Security Council podcast.
Security News
Research
Socket researchers uncover how threat actors weaponize Out-of-Band Application Security Testing (OAST) techniques across the npm, PyPI, and RubyGems ecosystems to exfiltrate sensitive data.